import Ax from '../api';

const headers = {"Content-Type": "multipart/form-data"};

export default {
  fileUpload: (formData, param = {}) => Ax.post(`/file/upload?type=${param.type}&assetType=${param.assetType}&previewType=${param.previewType}&imageType=${param.imageType}`, formData, {headers: headers}),
  fileDelete: (query) => Ax.delete(`/file/delete?_id=${query._id}`),
  commonAssetList: () => Ax.get(`/file/common/asset/list`),
  fileUpdate: (param) => Ax.post(`/file/common/asset/update`, param),
};
